/*Comments here*/

#include<stdio.h>
#include"add.h"
#include"substract.h"
#include"multiply.h"
#include"mod.h"
#include"typein.h"


void main(){
	compute typein();
	compute c1;
	int judge=1;
	float result;
	while(judge){
		c1=typein();
		switch(c1.symbol){
		case'+':result=add(c1.a,c1.b);break;
		case'-':result=substract(c1.a,c1.b);break;
		case'*':result=multiply(c1.a,c1.b);break;
		case'%':result=mod(c1.a,c1.b);break;
		}
		printf("answer:%f\n",result);
		printf("go on(input 1) or not(input 0)?\n");
		scanf("%d",&judge);
		while(judge!=0&&judge!=1){printf("invaild input,please input again");scanf("%d",&judge);continue;};
		
		
	};
}

